import request from '../utils/request';

export function createNavigationTags(params) {
  return request({
    url: '/navigation/createNavigationTags',
    method: 'post',
    data: params
  });
}

export function createRankNavigation(params) {
  return request({
    url: `/navigation/createRankNavigation`,
    method: 'post',
    data: params
  });
}

export function deleteNavigation(navId) {
  return request({
    url: `/navigation/deleteNavigation/${navId}`,
    method: 'post'
  });
}

export function deleteNavigationTags(tagsId) {
  return request({
    url: `/navigation/deleteNavigationTags/${tagsId}`,
    method: 'post'
  });
}

export function findFirstRankNavigation() {
  return request({
    url: `/navigation/findFirstRankNavigation`,
    method: 'get'
  });
}

export function findNavigationByFirstRank(params) {
  return request({
    url: `/navigation/findNavigationByFirstRank`,
    method: 'get',
    params: params
  });
}

export function findTags(params) {
  return request({
    url: `/navigation/findTags`,
    method: 'post',
    data: params
  });
}

export function updateRankNavigation(params) {
  return request({
    url: `/navigation/updateRankNavigation`,
    method: 'post',
    data: params
  });
}
